<script setup>
const props = defineProps({
  data: {
    type: Array,
    default: () => {
      return []
    }
  }
})
</script>

<template>
  <div class="list">
    <dv-button class="list-item" border="Border6" :color="machine.Color" v-for="machine in data" :key="machine.Color">
      <div style="width: 100%; height: 100%; display: flex; justify-content: space-between; align-items: center">
        <img class="item-content" :src="machine.Src" />

        <div style="display: flex; flex-direction: column; justify-content: space-around; height: 100%">
          <div style="color: #d6ebff; font-size: 24px">{{ machine.Total }}</div>
          <div style="color: #cbccd3">{{ machine.Text }}</div>
        </div>
      </div>
    </dv-button>
  </div>
</template>

<style scoped lang="scss">
@font-face {
  font-family: 'UnidreamLED';
  src: url(../../../assets/font/DS-Digital/DS-DIGI-1.ttf); /***兼容ie9***/
}

.list {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  padding: 10px;
  .list-item {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    color: #fff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;

    .item-content {
      width: 50px;
      transform: scale(1.5);
    }

    .title {
      font-size: 14px;
    }

    .number {
      font-size: 18px;
      font-weight: bold;
    }
  }
}
.dom-box {
  display: flex;
  flex-direction: column;
  height: 100%;

  .dom-title {
    height: 40px;
    background-color: rgba(14, 58, 119, 0.6);
    color: #2ca7e2;
    line-height: 40px;
    padding-left: 20px;
  }

  .dom-content {
    flex: 1;
    height: 100%;
    overflow: hidden;
    display: flex;
    flex-direction: column;
  }
  .chart-content {
    flex: 1;
    overflow: hidden;

    height: calc(100% - 70px);
  }
}
</style>
